FROM python:3.10.12-alpine3.18 as pa
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.ustc.edu.cn/g' /etc/apk/repositories
RUN apk update && apk upgrade
RUN apk add musl-dev gcc g++ snappy-dev
WORKDIR /app
COPY entrypoint.sh .
COPY requirements.txt .
COPY monitor_tasks monitor_tasks
RUN chmod +x ./entrypoint.sh
RUN pip install -i http://172.16.43.255:3141/root/local/+simple/ --trusted-host 172.16.43.255 --no-cache-dir --upgrade pip
RUN pip install -i http://172.16.43.255:3141/root/local/+simple/ --trusted-host 172.16.43.255 --no-cache-dir -r ./requirements.txt

ENTRYPOINT ["./entrypoint.sh"]

